package com.zdemo.threadfactory;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.ThreadPoolExecutor;
import java.util.concurrent.TimeUnit;

public class Test {
	ThreadPoolExecutor executor = 
			new ThreadPoolExecutor(10, 10, 0L, TimeUnit.MICROSECONDS, 
					new LinkedBlockingQueue<Runnable>(10));
	public static void main(String[] args) {
		
		ExecutorService executor = Executors.newSingleThreadExecutor(new MyThreadFactory("My"));  
		executor.submit(new Runnable() {

			@Override
			public void run() {
				System.out.println("******");
			}
			
		});
	}
}
